package com.gamecauca.item;

import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.gamecauca.common.Constant;
import com.gamecauca.common.GameConfig;
import com.gamecauca.common.GameObject;

public class GameItem extends GameObject {

	private String info;
	private int quantity;
	private int order;// thứ tụ của vị trí trong thùng đồ từ 0-->8/ tương tứng với 9 ô trong thùng đồ
	private int itemState;
	private int kind;
	
	public GameItem(int kind){
		this.kind = kind;
		this.price = GameConfig.getPrice(kind);
		this.effectTime = GameConfig.getEffectTime(kind);
		this.effectValue = GameConfig.getEffectValue(kind);
		info = GameConfig.getItemInfo(kind);
		itemState = Constant.ITEMINFISHING;
	}
	public GameItem(int kind,int state){
		this.kind = kind;
		this.price = GameConfig.getPrice(kind);
		this.effectTime = GameConfig.getEffectTime(kind);
		this.effectValue = GameConfig.getEffectValue(kind);
		info = GameConfig.getItemInfo(kind);
		itemState = state;
	}
	public GameItem(int kind,int state,int x,int y,float width, float height){
		super(x, y, width, height);
		this.kind = kind;
		this.price = GameConfig.getPrice(kind);
		this.effectTime = GameConfig.getEffectTime(kind);
		this.effectValue = GameConfig.getEffectValue(kind);
		info = GameConfig.getItemInfo(kind);
		itemState = state;
	}
	public void update() {
		
	}
	public  void render(SpriteBatch batch){
		
	}

	public void setPrice(int price) {
		this.price = price;
	}

	public int getPrice() {
		return price;
	}

	public void setInfo(String info) {
		this.info = info;
	}

	public String getInfo() {
		return info;
	}

	public void setQuantity(int quantity) {
		this.quantity = quantity;
	}

	public int getQuantity() {
		return quantity;
	}

	public void setOrder(int order) {
		this.order = order;
	}

	public int getOrder() {
		return this.order;
	}
	public void  setState(int state){
		itemState= state;
	}
	public int  getState(){
		return itemState ;
	}
	public void setKind(int ikind) {
		kind = ikind;
	}
	public int getKind() {
		return kind ;
	}

}
